package tables

import (
	"time"
)

type CouponOrder struct {
	Id                     int       `xorm:"not null pk autoincr INT(10)" json:"id" form:"id" mapstructure:"id"`
	UserId                 int       `xorm:"" json:"user_id" form:"user_id" mapstructure:"user_id"`
	CouponId               int       `xorm:"" json:"coupon_id" form:"coupon_id" mapstructure:"coupon_id"`
	MerUserId              int       `xorm:"" json:"mer_user_id" form:"mer_user_id" mapstructure:"mer_user_id"`
	OrderNo                string    `xorm:"" json:"order_no" form:"order_no" mapstructure:"order_no"`
	Coupon                 string    `xorm:"" json:"coupon" form:"coupon" mapstructure:"coupon"`
	CouponName             string    `xorm:"" json:"coupon_name" form:"coupon_name" mapstructure:"coupon_name"`
	CouponCondition        string    `xorm:"" json:"coupon_condition" form:"coupon_condition" mapstructure:"coupon_condition"`
	CouponValidNum         int       `xorm:"" json:"coupon_valid_num" form:"coupon_valid_num" mapstructure:"coupon_valid_num"`
	CouponValidDay         int       `xorm:"" json:"coupon_valid_day" form:"coupon_valid_day" mapstructure:"coupon_valid_day"`
	CouponExpireTime       int       `xorm:"" json:"coupon_expire_time" form:"coupon_expire_time" mapstructure:"coupon_expire_time"`
	CouponMerchantName     string    `xorm:"" json:"coupon_merchant_name" form:"coupon_merchant_name" mapstructure:"coupon_merchant_name"`
	CouponMerchantInfo     string    `xorm:"" json:"coupon_merchant_info" form:"coupon_merchant_info" mapstructure:"coupon_merchant_info"`
	CouponMerchantLocation string    `xorm:"" json:"coupon_merchant_location" form:"coupon_merchant_location" mapstructure:"coupon_merchant_location"`
	CouponLastUseTime      int       `xorm:"" json:"coupon_last_use_time" form:"coupon_last_use_time" mapstructure:"coupon_last_use_time"`
	CouponIsGive           int       `xorm:"" json:"coupon_is_give" form:"coupon_is_give" mapstructure:"coupon_is_give"`
	CouponMaxGiveNum       int       `xorm:"" json:"coupon_max_give_num" form:"coupon_max_give_num" mapstructure:"coupon_max_give_num"`
	CouponMan              float32   `xorm:"" json:"coupon_man" form:"coupon_man" mapstructure:"coupon_man"`
	CouponJian             float32   `xorm:"" json:"coupon_jian" form:"coupon_jian" mapstructure:"coupon_jian"`
	CouponZhe              int       `xorm:"" json:"coupon_zhe" form:"coupon_zhe" mapstructure:"coupon_zhe"`
	CouponIsOneCard        int       `xorm:"" json:"coupon_is_one_card" form:"coupon_is_one_card" mapstructure:"coupon_is_one_card"`
	GiveId                 int       `xorm:"" json:"give_id" form:"give_id" mapstructure:"give_id"`
	GiveUserId             int       `xorm:"" json:"give_user_id" form:"give_user_id" mapstructure:"give_user_id"`
	Name                   string    `xorm:"" json:"name" form:"name" mapstructure:"name"`
	Phone                  string    `xorm:"" json:"phone" form:"phone" mapstructure:"phone"`
	Form                   string    `xorm:"" json:"form" form:"form" mapstructure:"form"`
	PayAmount              int       `xorm:"" json:"pay_amount" form:"pay_amount" mapstructure:"pay_amount"`
	PayTime                int       `xorm:"" json:"pay_time" form:"pay_time" mapstructure:"pay_time"`
	PayStatus              int       `xorm:"" json:"pay_status" form:"pay_status" mapstructure:"pay_status"`
	HexiaoTime             int       `xorm:"" json:"hexiao_time" form:"hexiao_time" mapstructure:"hexiao_time"`
	Fid                    int       `xorm:"" json:"fid" form:"fid" mapstructure:"fid"`
	RelPath                string    `xorm:"" json:"rel_path" form:"rel_path" mapstructure:"rel_path"`
	FailMsg                string    `xorm:"" json:"fail_msg" form:"fail_msg" mapstructure:"fail_msg"`
	ExpireTime             int       `xorm:"" json:"expire_time" form:"expire_time" mapstructure:"expire_time"`
	Remark                 string    `xorm:"" json:"remark" form:"remark" mapstructure:"remark"`
	CreatedAt              time.Time `xorm:"created" json:"created_at" form:"created_at" mapstructure:"created_at"`
	UpdatedAt              time.Time `xorm:"updated" json:"updated_at" form:"updated_at" mapstructure:"updated_at"`
	DeletedAt              time.Time `xorm:"deleted" json:"deleted_at" form:"deleted_at" mapstructure:"deleted_at"`
	SeparateState          int       `xorm:"" json:"separate_state" form:"separate_state" mapstructure:"separate_state"`
	TransactionId          string    `xorm:"" json:"transaction_id" form:"transaction_id" mapstructure:"transaction_id"`
	IpAddr                 string    `xorm:"" json:"ip_addr" form:"ip_addr" mapstructure:"ip_addr"`
	Address                string    `xorm:"" json:"address" form:"address" mapstructure:"address"`
	TrackingNumber         string    `xorm:"" json:"tracking_number" form:"tracking_number" mapstructure:"tracking_number"`
	TrackingCompany        string    `xorm:"" json:"tracking_company" form:"tracking_company" mapstructure:"tracking_company"`
	TrackingState          int       `xorm:"" json:"tracking_state" form:"tracking_state" mapstructure:"tracking_state"`
}
